package com.zyf.chapter02.structure.bridge;

import com.zyf.chapter02.structure.bridge.Notification;
import com.zyf.chapter02.structure.bridge.sender.MsgSender;

/**
 * 不重要的报警
 * @author yifeng
 */
public class TrivialNotification extends Notification {

    /**
     * 通过依赖注入，注入想要的通知类型，不依赖于实现
     */
    public TrivialNotification(MsgSender msgSender) {
        super(msgSender);
    }

    @Override
    public void notify(String message) {
        msgSender.send(message);
    }
}
